package com.xcx.robot.mirai.jxapi;

import lombok.Data;
import org.apache.commons.lang3.StringUtils;

import java.io.Serializable;

/**
 * @Author: 邢晨旭
 * @Date: 2021/6/9 16:07
 * @Description:
 */
@Data
public class ResultData implements Serializable {
    private String name;
    private String holes;//奇穴
    private String command;//宏

    private String text;//骚话
    /**
     * DateTime : 2021-06-22
     * Week : 二
     * DayWar : 英雄梧桐山庄
     * DayBattle : 三国古战场
     * DayCommon : 藏剑·乱世
     * DayCamp : 经首道源
     * WeekCommon : 千岛湖·温泉战倭;侠客岛·雾岛寻丹
     * WeekFive : 璨翠海厅;英雄华清宫;英雄夕颜阁
     * WeekTeam : 白帝江关;烛龙殿;荻花宫后山
     */

    private String date;
    private String week;
    private String dayWar;
    private String dayBattle;
    private String dayPublic;
    private String dayCamp;
    private String dayDraw;
    private String weekPublic;
    private String weekFive;
    private String weekTeam;


    /**
     * 日常输出
     *
     * @return
     */
    public String getDaily() {
        //秘境大战：英雄梧桐山庄
        //今日战场：三国古战场
        //公共任务：藏剑·乱世
        //阵营任务：经首道源
        //阵营攻防：逐鹿中原(20:00)
        //活动∶节日・端午
        //绝境战场∶12:00-1:00
        //列星虚境∶10:00-3:00
        //小攻防∶20:00-22:00
        //提醒∶19:28记得卡攻防排队！
        //每天七点更新，日常召唤CD50秒
        StringBuilder result = new StringBuilder();
        result.append("\n秘境大战：").append(this.dayWar).append("\n");
        result.append("今日战场：").append(this.dayBattle).append("\n");
        result.append("公共任务：").append(this.dayPublic).append("\n");
        result.append("阵营任务：").append(this.dayCamp).append("\n");
        if (StringUtils.equalsAny(week, "二", "四")) {
            result.append("阵营攻防：").append("逐鹿中原(20:00)").append("\n");
        }
        if (StringUtils.isNotEmpty(this.dayDraw)) {
            result.append("美人图：").append(this.dayDraw).append("\n");
        }
        result.append("\n武林通鉴·公共任务\n").append(this.weekPublic).append("\n");
        result.append("武林通鉴·秘境任务\n").append(this.weekFive).append("\n");
        result.append("武林通鉴·团队秘境\n").append(this.weekTeam).append("\n");
//        result.append("\n绝境战场∶12:00-1:00\n列星虚境∶10:00-3:00");
        return result.toString();
    }

    /**
     * id : 63000
     * price : 6100
     * region : 电信点卡
     * regionAlias : 电点
     * regionId : 1
     * server : 双梦
     * serverId : 1
     * saleCode : 出给牛
     * tradeTime : 21/03/22
     * outwardName : null
     * outwardId : 620
     * audit : 0
     * now : 0
     * exterior : 包身盒子
     * pricer : 猕猴桃
     * itemname : 九阙天影礼盒
     * https://jx3api.com/app/price?name=
     */

    private String id;
    private String price;
    private String region;
    private String regionAlias;
    private String regionId;
    private String server;
    private String serverId;
    private String saleCode;
    private String tradeTime;
    private Object outwardName;
    private String outwardId;
    private String audit;
    private String now;
    private String exterior;
    private String pricer;
    private String itemname;


    public String getPrice() {
        return String.join(" ", this.regionAlias, this.server, this.tradeTime, this.price + this.saleCode);
    }


    /**
     * method : 完成武林通鉴·公共任务有几率触发，打掉藏宝洞首领之后洞主有几率触发
     * need : 觅宝会声望达到敬重，获得至少两个不重复的挖宝挂件（北谢囊、扣舷鼓、弦歌瓶、洞庭卷，已装备或放在背包中均可，装备第三个挂件开始增加触发几率）
     * other : 资历无确切要求，目前已知最低触发的是“20000”左右
     * reward : 腰部挂件“泥人·丢丢”，披风衣饰“漆夜·栽火莲”，交互动作“举高高”，穿山甲跟宠“葫芦”
     */

//    private String method;
//    private String need;
//    private String other;
//    private String reward;
    private String image;



}

